
<html> 
    <head>
        <link href="style3.css" rel="stylesheet" type="text/css" />   
        </form>
    </head> 
</html>
<?php



$conn = mysql_connect("localhost", "root", "") or die(mysql_error());
mysql_select_db("mydb", $conn) or die(mysql_error());

if(isset($_GET['submitplace']))
    
{
    $place = $_GET['place'];
    $query = mysql_query ("SELECT * FROM conference where conference.place='{$place}'") 
    // Query to select all the conferences that exist in the same place the user enters in the text box
    or die('here' . mysql_error());
    //table containing all the conferences available
echo '<table width="100%">
    <tr>
    <td><b>Conference</b>
    </td>
    </tr>';

//redirect to the conference page 
while ($row = mysql_fetch_assoc($query)) {
    echo "<tr>
	  <td>{$row['long_name']}</td> 
	  <td><a href='conferencePage.php?conference_id={$row['conference_id']}'>go to Conference</a </td> 
	  </tr>";
}



echo '</table>';
}

if(isset($_GET['submitareaOfexper']))
    
{
    $data = $_GET['area'];
    $query = mysql_query ("SELECT * FROM conference where conference.area_of_expertise='{$data}'") 
    or die('here' . mysql_error());
       // Query to select all the conferences that exist in the same area_of_expertise the user enters in the text box
    //table containing all the conferences available
echo '<table width="100%">
    <tr>
    <td><b>Conference</b>
    </td>
    </tr>';

//redirect to the conference page 
while ($row = mysql_fetch_assoc($query)) {
    echo "<tr>
	  <td>{$row['long_name']}</td> 
	  <td><a href='conferencePage.php?conference_id={$row['conference_id']}'>go to Conference</a </td> 
	  </tr>";
}



echo '</table>';
}
?>
        

            </body>
</html>

